package day13.tarena.com;
import java.util.*;
public class TestHashSet {
	public static void main(String[] args) {
		Set set = new HashSet();
		set.add("one");
		set.add("six");
		set.add("three");
		set.add("eight");
		set.add("four");
		//System.out.println(set);
		set.remove("two");
		System.out.println(set);
		Iterator it = set.iterator();   //it是我们创建的
		while(it.hasNext()){
				Object obj = it.next();
				if(obj instanceof String){
					String s = (String)obj;
					System.out.println(s);
				}				
		}
	}
}
